<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isErrorPage="true" isELIgnored="false"%>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		<meta http-equiv="Content-Language" content="UTF-8" />
        <%@include file="../../common/commonCss.jsp"%>
        <%@include file="../../common/commonJs.jsp"%>
        <script src="js/menuManage.js"></script>
        <style>
            body{
                padding: 10px 10px 10px 30px;
            }
            .el-input{
                width: 192px;
            }
        </style>
	</head>

	<body>
    <div id="formApp">
        <i-form ref="formValidate" :label-width="90" :model="formValidate"  :rules="ruleInline"  inline>
            <form-item prop="name" label="资源名称：">
                <i-input type="text" v-model="formValidate.name" style="width: 192px;"  placeholder="请输入资源名称..."></i-input>
            </form-item>
            <form-item label="资源链接：">
                <i-input type="text" v-model="formValidate.resUrl" style="width: 192px;"  placeholder="请输入资源链接..."></i-input>
            </form-item>
            <form-item prop="type" label="资源类型：">
                <i-select v-model="formValidate.type" style="width:192px">
                    <i-option v-for="item in formValidate.menuTypeList" :value="item.value" :key="item.value">{{ item.label }}</i-option>
                </i-select>
            </form-item>
            <form-item prop="icon" label="资源图标：">
                <i-input type="text" v-model="formValidate.icon" style="width: 192px;"  placeholder="请输入资源图标..."></i-input>
            </form-item>
            <form-item prop="parentId" label="父级资源ID：">
                <i-input type="text" v-model="formValidate.parentId" style="width: 192px;"  placeholder="请输入父级资源ID..."></i-input>
            </form-item>
            <form-item prop="sort" label="排序号：">
                <input-number type="text" :min="0" v-model="formValidate.sort" style="width: 192px;"  placeholder="请输入排序号..."></input-number>
            </form-item>
            <div style="text-align: center;">
                <i-button type="primary" :loading="formValidate.loading" @click="onSubmit('formValidate')" icon="paper-airplane">
                    <span v-if="!formValidate.loading">提交</span>
                    <span v-else>提交中...</span>
                </i-button>
                <i-button type="primary" @click="handleReset('formValidate')" :disabled="formValidate.disabledReset" icon="refresh" style="margin-left: 8px">重置</i-button>
            </div>
        </i-form>
    </div>
    <script>
       menuManage.fun.initForm(parent.vueGridApp.item);
    </script>

	</body>

</html>